package com.danco.training.zaneuskaya.cswworker;

import java.io.FileWriter;
import java.io.IOException;
import java.util.ArrayList;



import org.apache.log4j.Logger;



public class CSVSaver{
	public static final Logger logger = Logger.getLogger(CSVReader.class);

public static <T> void saveListToFile(String file, ArrayList<String> list ) throws IOException {
		
	
	
		try
		{
		FileWriter writer = new FileWriter(file,false);
		for(String t: list){
			
			writer.append(t);
			writer.append('\n');
			}
		
	        writer.close();
	    }
	    catch(IOException e)
	    {
	         logger.error(e.getMessage(), e);
	    }

	} 








}
